I don't know if these codes work or not. I've heard from some people that they work and from some people that they don't. I found these while surfing the net, so don't hold me responsible for something bad that happens to your saved game.

 

Make a Pokéball into a Master Ball (doesn't always work)

When you throw the pokéball, hold (up) and (b).

 

Make a Great Ball into a Master Ball (doesn't alway work)

When you throw the Great Ball, hold (down) and (b).